<?php $this->load->view('admin/_header2') ?>

<table id="tt" class="easyui-datagrid" style="width:960px;height:auto;">
	<thead>
	<tr height=32 >
		<th field="name0" align=center  width=200 >Date</th>
		<th field="name1" align=center  width=200 >Visitor's IP</th>
		<th field="name2" align=center  width=200 >Page view</th>
		<th field="name4" align=center  width=100 ></th>
	</tr>
	</thead>
	<tbody>
	<?php
	
	$index=0;
	$sumVorIP=0;
	$sumPview=0;
	foreach($result as $item)
	{
		$sumVorIP += (int)($item->VorIP);
		$sumPview += (int)($item->PageView);
		$index++;
	?><tr align=center >
		<td><?=$item->visitDate ?></td>
		<td><?=$item->VorIP  ?></td>
		<td><?=$item->PageView  ?></td>
		<td><a target="_self" href="querryVisitorsReportDetails?CurDate=<?=$item->visitDate ?>&AgenctCode=<?=$Agency ?>">View Details</a></td>
	</tr>
	<?php
	}
	?>
    <tr>
    	<td><strong>Total</strong></td>
        <td><?=$sumVorIP ?></td>
        <td><?=$sumPview ?></td>
        <td></td>
    </tr></tbody>
</table>

<?php $this->load->view('admin/_footer1') ?>